
<div class="row">
	<div class="col-xs-12">
		<div class="box box-primary">
		  <div class="box-header">
		    <h3 class="box-title">Edit Data Online Support</h3>
		  </div><!-- /.box-header -->
      <?=form_open_multipart('services_online_support/update', array('role' => 'form', 'id' => 'form')); 
				if(!empty($list)){
					?>
		        <div class="box-body">				        
							<input type="hidden" name="id_online_support" value="<?=$list['id_online_support']?>" />
							<div class="form-group">
	              <label>Nama</label>
								<input value="<?=$list['nama']?>" class="form-control input-sm" name="nama" type="text" placeholder="Nama">
							</div>
							<div class="form-group">
	              <label>Username</label>
								<input value="<?=$list['username']?>" class="form-control input-sm" name="username" type="text" placeholder="Username">
							</div>
		          <!-- text input -->
		          <?php if (isset($_SERVER['HTTP_REFERER'])) {?>
				        <input type="hidden" name="redirurl" value="<?php echo $_SERVER['HTTP_REFERER'];?>" />
				      <?php }?>
			      </div>		                   
	          <div class="box-footer">
	            <button type="submit" class="btn btn-sm btn-primary btn-flat"><i class="fa fa-floppy-o"></i> Update</button>
	          </div>
	        <?php 
				}else{
					?>
						Tidak ada data
					<?php 
				}
				echo form_close();
			?>
		</div><!-- /.box -->                            
	</div>
</div>

<script>
	$("#form").validate({
		rules: {
			nama: {
				required: true
			},
			username: {
				required: true
			}
		}
	});
</script>